/**
 * Copyright 2020 OPSLI 快速开发平台 https://www.opsli.com
 * <p>
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
 * use this file except in compliance with the License. You may obtain a copy of
 * the License at
 * <p>
 * http://www.apache.org/licenses/LICENSE-2.0
 * <p>
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
 * License for the specific language governing permissions and limitations under
 * the License.
 */
package org.opsli.modulars.business.patrolStation.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.opsli.api.wrapper.business.patrolStation.PatrolStationModel;
import org.opsli.modulars.business.patrolRouteRecord.entity.PatrolRouteRecord;
import org.opsli.modulars.business.patrolStation.entity.PatrolStation;
import org.opsli.modulars.business.patrolStation.entity.PatrolStationWeb;

import java.util.List;

/**
 * 巡点管理 Mapper
 *
 * @author zk
 * @date 2021-09-14 15:53:53
 */
@Mapper
public interface PatrolStationMapper extends BaseMapper<PatrolStation> {

    List<PatrolStationModel> findList(String devid);

    Integer getSum(@Param("devid") String devid,@Param("type") String type);

    List<PatrolStationModel> findListFm(String devid);

    List<PatrolStationModel> findListByType(@Param("devid") String devid,@Param("type") String type);

    List<PatrolStationModel> findListByControlAreaText(@Param("devid") String devid,@Param("type") String type,@Param("controlAreaText") String controlAreaText);

    List<PatrolStationModel> findListByTypeAndName(@Param("devid") String devid,@Param("type") String type,@Param("stationName") String stationName);

    public List<PatrolStationModel> getMyList( @Param("model") PatrolStationModel announcementSendModel,@Param("beginSize") Integer beginSize,@Param("endSize") Integer endSize);

    //根据阀门井测点名称查出阀门井编号
    PatrolStationModel getId(@Param("valveName") String valveName);

    //获取调压柜  type4
    List<PatrolStationModel> getCabinetList(@Param("devid") String devid);
    //根据小区名称获取其中一个调压箱
    List<PatrolStationModel> findListByTypeName(@Param("devid") String devid,@Param("type") String type,@Param("villageName")String villageName);

    //根据位置描述获取调压柜Id
    PatrolStationModel findListByLocation(@Param("devid") String devid,@Param("type") String type,@Param("location")String location);

    List<PatrolStationModel> findListQu(String id);

    void updateClear(String id);

}
